package com.supermap.data.modal;

import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
import org.hibernate.annotations.GenericGenerator;

import javax.persistence.*;

/**
 * 用户信息（基本信息、角色组、部门组）
 * TUser entity. @sun'f
 */
@Entity
@Table(name = "T_USER")
public class TUsers implements java.io.Serializable {

    /**
     * 记录主键 uuid
     */
    private String id;
    /**
     * 用户名
     */
    private String user_name;

    /**
     * 用户密码
     */
    private String password;
    /**
     * 部门代码
     */
    private String dep_code;
    /**
     * 行政区划
     */
    private String region;
    /**
     * 邮箱
     */
    private String email;
    /**
     * 联系方式
     */
    private String phone;
    /**
     * 所属角色
     */
    private String role;
    /**
     * 所属角色
     */
    private int status;



    public TUsers() {};


    public TUsers(String id, String user_name, String password, String dep_code, String region, String email, String phone, String role, int status) {
        this.id = id;
        this.user_name = user_name;
        this.password = password;
        this.dep_code = dep_code;
        this.region = region;
        this.email = email;
        this.phone = phone;
        this.role = role;
        this.status = status;
    }

    @Id
    @GeneratedValue(generator = "uuid")
    @GenericGenerator(name = "uuid", strategy = "uuid")
    @Column(name = "id")
    public String getId() {
        return this.id;
    }

    public void setId(String id) {
        this.id = id;
    }

    @Column(name = "USER_NAME", length = 100)
    public String getUser_name() {
        return user_name;
    }

    public void setUser_name(String user_name) {
        this.user_name = user_name;
    }

    @Column(name = "PASSWORD", length = 100)
    public String getPassword() {
        return password;
    }

    public void setPassword(String password) {
        this.password = password;
    }

    @Column(name = "DEP_CODE", length = 100)
    public String getDep_code() {
        return dep_code;
    }

    public void setDep_code(String dep_code) {
        this.dep_code = dep_code;
    }

    @Column(name = "REGION", length = 100)
    public String getRegion() {
        return region;
    }

    public void setRegion(String region) {
        this.region = region;
    }

    @Column(name = "EMAIL", length = 100)
    public String getEmail() {
        return email;
    }

    public void setEmail(String email) {
        this.email = email;
    }

    @Column(name = "PHONE", length = 100)
    public String getPhone() {
        return phone;
    }

    public void setPhone(String phone) {
        this.phone = phone;
    }

    @Column(name = "ROLE", length = 100)
    public String getRole() {
        return role;
    }

    public void setRole(String role) {
        this.role = role;
    }

    @Column(name = "STATUS", length = 100)
    public int getStatus() {
        return status;
    }

    public void setStatus(int status) {
        this.status = status;
    }
}